<?php

namespace Action\User;

class PreferencesDialog extends \Library\Action\UserAction 
	implements \Library\Action\AjaxAction {

	private $_tabPane;
	private $_authUser;
	
	public function getTabPane() {
		if( $this->_tabPane === null ) {
			$this->_tabPane = new \Library\Widget\TabPane();
			$this->_tabPane->getTab( 'account' )
				->setTitle( 'Account' )
				->setContent( _view( 'Account', $this ) );
		}
		return $this->_tabPane;
	}
	
	public function getAuthUser() {
		if( $this->_authUser === null ) {
			$this->_authUser = new \Library\Auth\User( $this->getUser() );
		}
		return $this->_authUser;
	}

}
